<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no"/>
    <title>问卷简答题</title>
    <link rel="stylesheet" type="text/css" href="${s.base}/lib/layui/css/layui.css"/>
    <link rel="stylesheet" type="text/css" href="${s.base}/css/base/index.css"/>
    <link rel="stylesheet" type="text/css" href="${s.base}/lib/dtree/dtree.css"/>
    <link rel="stylesheet" type="text/css" href="${s.base}/lib/dtree/font/iconfont.css"/>
    <link rel="stylesheet" type="text/css" href="${s.base}/css/base/darkBlue.css"/>
    <link rel="stylesheet" type="text/css" href="${s.base}/css/work/question/question.css"/>
    <style>
        .quesition-tj-list dl dd {
            padding: 10px 0px 10px;
        }
    </style>
</head>
<body class="wrap-container clearfix">
<div class="column-content-detail">
    <div class="quesition-tj-tit">${question.title}</div>
    <div class="questionnaire-style-txt">
        <p>问卷类型：<span><#if question?? && question.type == '1'>扫码问卷<#else>对象问卷</#if></span>
            <#if question?? && question.type == '2'>
            问卷对象：<span><#if question?? && question.objectType == '1'>
                            所有人
                            <#elseif question?? && question.objectType == '2'>
                            教师
                            <#elseif question?? && question.objectType == '3'>
                            学生
                            <#else>
                            自定义对象
                            </#if>
                </span>
            </#if>
        </p>
        <p>开放时间：${question.startTime?string('yyyy-MM-dd')}~${question.endTime?string('yyyy-MM-dd')}</p>
        <#if question?? && question.remark !=null && question.remark !="">
        <p>问卷描述：<span>${question.remark}</span></p>
        </#if>
    </div>
    <div class="layui-form" id="table-list">
        <table id="entityList" lay-filter="entityList" class="cy-list-table"></table>
    </div>
</div>
<script src="${s.base}/lib/layui/layui.js" type="text/javascript" charset="utf-8"></script>
<script src="${s.base}/js/common.js" type="text/javascript" charset="utf-8"></script>
<script src="${s.base}/lib/KnifeZ/ace/ace.js" type="text/javascript" charset="utf-8"></script>
<script>
    var layer = null, tableIns = null;
    layui.use(['form', 'jquery', 'page', 'fileUtil', 'dialog', 'layer', 'layedit', 'baseutil'], function () {
        var $ = layui.jquery,
            form = layui.form,
            page = layui.page,
            fileUtil = layui.fileUtil,
            baseutil = layui.baseutil,
            layer = layui.layer,
            layedit = layui.layedit,
            dialog = layui.dialog;
        form.render();

        var id = '${question.id}';
        var subjectId = '${subjectId}';

        $('#cancel').bind('click', function () {
            if (id) {
                parent.tabDelete(id);
            } else {
                parent.tabDelete('questionEdit');
            }
        });

        //获取分页数据
        var url = "/work/questionscore/page?questionId="+id+"&subjectId="+subjectId;
        var cols = [
            {type: 'numbers', title: '序号'},
            {
                field: 'scoreList', title: '简答题', align: 'center', templet: function (d) {
                    return d.scoreList;
                }
            }
        ];
        tableIns = page.initDate(cols, url);
    });

</script>
</body>
</html>